<div class="col-sm-12">
	<div class="box shadow">
		<!-- BOX-BODY -->
		<div class="box-body">
			<!-- 列表编辑-->
			{{#bs-form formLayout=formLayout model=projectModel invalid=(action "invalid")}}
			<div class="row">

				<div class="col-xs-12">
					<p class="user-add-btn">
						{{#if detailEdit}}
							{{#ui/mix-button class="user-btn edit-btn" iconClass="fa fa-save"  text='保存' clickAction="detailSaveClick" detailSaveClick="detailSaveClick" clickActParams=projectModel}}
							{{/ui/mix-button}}
							{{#ui/mix-button class="user-btn times-btn" iconClass="fa fa-undo"  text='取消'  clickAction="detailCancel" detailCancel="detailCancel" }}
							{{/ui/mix-button}}
						{{else}}
							{{#ui/mix-button class="user-btn edit-btn" iconClass="fa fa-edit"  text='编辑'  clickAction="detailEditClick" detailEditClick="detailEditClick" clickActParams=projectInfo}}
							{{/ui/mix-button}}
							{{#ui/mix-button class="user-btn trash-btn" iconClass="fa fa-trash-o"  text='删除'  clickAction="delById" delById="delById"}}
							{{/ui/mix-button}}
						{{/if}}
					</p>
				</div>
					<div class="col-xs-12 nopadding-horizontal mt20">
						<div class="col-xs-12 col-sm-6">
							<div class="form-input-group">
								<span class="input-group-addon">姓&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;名：</span>
									<div class="input-group-content">{{projectInfo.customer.name}}</div>
							</div>

						</div>

						<div class="col-xs-12 col-sm-6">
							<div class="form-input-group">
								<span class="input-group-addon">价格(元/月)：</span>
								{{#if detailEdit}}
										{{bs-form-element property="price" class="inline-block form-input-group label-normal" controlType="price" placeholder='价格(必填)'}}

								{{else}}
									<div class="input-group-content">{{projectInfo.price}}</div>
								{{/if}}
							</div>

						</div>

            <div class="col-xs-12 col-sm-6">
							<div class="form-input-group">
								<span class="input-group-addon">参&nbsp;考&nbsp;问&nbsp;卷：</span>
								<div class="input-group-content" {{action "toEva" on="click"}}><a>查看对应问卷</a></div>
							</div>

						</div>

            <div class="col-xs-12 col-sm-6">
              <div class="form-input-group">
                <span class="input-group-addon">创&nbsp;建&nbsp;时&nbsp;间&nbsp;：</span>
                <div class="input-group-content">
                  {{projectInfo.createTime}}
                </div>
              </div>

            </div>
						{{#unless detailEdit}}
						<div class="col-xs-12 col-sm-6">
							<div class="form-input-group">
								<span class="input-group-addon">照&nbsp;护&nbsp;项&nbsp;目&nbsp;：</span>
								<div class="input-group-content">
			            {{chooseService}}
								</div>
							</div>

						</div>
						{{/unless}}
					</div>
			</div>
			<!-- 列表编辑 -->
			{{/bs-form}}
		</div>
		<!-- /BOX-BODY -->
	</div>
	{{#if detailEdit}}
		<div class="box nopadding-left nopadding-right nopadding-vertical border blue service-list shadow">
			<div class="box-title nopadding-left">
				<div class="title">护理项目</div>
				<div class="remark"><img class="" src="assets/images/logo/fire.png">代表问卷推荐项目</div>
				<div class="remark">字体加粗代表已选项目</div>
			</div>
			<div class="box-body">
				<table class="table table-hover">
					<thead>
						<tr  role="row">
							<th rowspan="1" colspan="1" width="70px"></th>
							<th rowspan="1" colspan="1" width="15%">项目名称</th>
							<th rowspan="1" colspan="1" width="">护理类别</th>
							<th rowspan="1" colspan="1" width="">类别</th>
							<th rowspan="1" colspan="1" width="">周期</th>
							<th rowspan="1" colspan="1" width="">频次</th>
							<th rowspan="1" colspan="1" width="15%">参考时长</th>
							<th rowspan="1" colspan="1" width="50px"></th>
						</tr>
					</thead>
					<tbody class="">
						{{#each allServiceList as |service|}}
						<tr class="{{if service.hasChoosed 'strong' ''}}">
							<td class="ellipsis" {{action "chooseService" service on="click"}}>
								{{#if service.strong}}
									<img class="pull-right" src="assets/images/logo/fire.png">
								{{/if}}
							</td>
							<td class="ellipsis" {{action "chooseService" service on="click"}}>{{service.ent.name}}</td>
							<td class="ellipsis" {{action "chooseService" service on="click"}}>{{service.ent.careType.typename}}</td>
							<td class="ellipsis" {{action "chooseService" service on="click"}}>{{service.ent.countType.typename}}</td>
							<td class="ellipsis" width="10%">
								{{#if service.hasChoosed}}
										{{#if service.count}}
											{{callbusi/dict-selector class="inline-block" curDict=service.ent.period groupCode=constants.period
												showName=service.ent.period.typename value=service.ent.period preselected=false}}
												{{else}}
												<div class='item' {{action "chooseService" service on="click"}}></div>
										{{/if}}
								{{else}}
									<div class='item' {{action "chooseService" service on="click"}}>{{service.ent.period.typename}}</div>
								{{/if}}
							</td>
							<td class="ellipsis" width="10%">
								{{#if service.hasChoosed}}
									{{#if service.count}}
										{{input class="form-control" type="text" placeholder=service.ent.frequency value=service.ent.frequency}}
										{{else}}
										<div class='item' {{action "chooseService" service on="click"}}></div>
									{{/if}}
								{{else}}
									<div class='item' {{action "chooseService" service on="click"}}>{{service.ent.frequency}}</div>
								{{/if}}
							</td>
							<td class="ellipsis" {{action "chooseService" service on="click"}}>{{service.ent.serviceTime}}</td>
							<td></td>
						</tr>
						{{/each}}
					</tbody>
				</table>
			</div>
		</div>
	{{/if}}
</div>


{{#if showpopInvitePassModal}}
	{{#bs-modal body=false footer=false header=false}}
		{{#bs-modal-header}}
			<h3 class="modal-title">删除提示</h3>
		{{/bs-modal-header}}
		{{#bs-modal-body}}
			<h4 class="modal-title">是否删除该条记录？</h4>
		{{/bs-modal-body}}
		{{#bs-modal-footer as |footer|}}
			{{#bs-button action=(action "cancelPassSubmit" projectInfo) type="primary" disabled=prepaidDisabled}}确定{{/bs-button}}
			{{#bs-button action=(action "invitation") type="default"}}取消{{/bs-button}}
		{{/bs-modal-footer}}
	{{/bs-modal}}
{{/if}}
